<template>
	<view class="goodsInfo">
		<n-loading></n-loading>
		<view v-if="goodsInfo">
			<!-- 商品banner处 -->
			<view class="goodsBanner">
				<view class="bannerBox">
					<!-- <u-swiper :list="bannerList" mode="number" height="750" indicator-pos="bottomRight" border-radius="0"></u-swiper> -->
					<swiper class="swiper" :duration="bannerSet.duration" @change="bannerChange" :autoplay="true">
						<swiper-item v-if="goodsInfo.video!=null">
							<!-- :poster="bannerList[0].file_url"  -->
							<view class="bannerImgBox">
								<video id="bannerVideo" 
								duration="15" 
								play-btn-position="bottom" 
								:src="goodsInfo.video" 
								@error="videoErrorCallback" 
								controls object-fit="cover"></video>
							</view>
						</swiper-item>
						<swiper-item v-for="(item,index) of bannerList" :key="index">
							<view class="bannerImgBox">
								<dh-image class="banner" :src="item" errorSrc="https://lovebirdopen.com/static/img/cBj/dPicture.png"></dh-image>
							</view>
						</swiper-item>
					</swiper>
					<!-- <view class="swiperNumber">{{ bCurrent + 1 }}/{{goodsInfo.video==''?bannerList.length:bannerList.length+1}}</view> -->
					<view class="swiperDots">
						<view class="swiperDot" v-if="goodsInfo.video!=null" :class="{swiperDotActive:bCurrent==0}"></view>
						<view class="swiperDot" :class="{swiperDotActive:bCurrent==(goodsInfo.video==null?index:(index+1))}" v-for="(item,index) of bannerList" :key="index"></view>
					</view>
				</view>
				<!-- 购买通报 -->
				<view class="buyNotice rowupGo" v-if="buyUser">
					<view class="buyNoticeCont">
						<image :src="buyUser.userInfo.avatar"></image>
						<text>{{buyUser.userInfo.nickname}}购买了本商品</text>
					</view>
				</view>
			</view>
			<!-- 商品信息 -->
			<view class="goodsInformation">
				<view class="priceShare">
					<view class="priceInfo">
						<text class="unit">¥</text>
						<text class="pPrice">{{specsIndex==-1?goodsInfo.price:goodsInfo.goods_product[specsIndex].price}}</text>
						<text class="oPrice">¥{{specsIndex==-1?goodsInfo.mktprice:goodsInfo.goods_product[specsIndex].mktprice}}</text>
					</view>
					<view class="shareXBtn">
						<author-login @clickAgain="followGo" height="48rpx" bgColor="transparent" :butImg="isFollow?'../../static/img/followEd.svg':'../../static/img/follow.svg'"></author-login>
					</view>
				</view>
				<view class="goodsName">{{goodsInfo.name}}</view>
				<view class="sales">
					<text>{{goodsInfo.brief}}</text>
				</view>
				<view class="sales clearfix">
					<text class="fr">销量 {{goodsInfo.buy_num}}</text>
				</view>
				<!-- 金币高粱穗抵扣 -->
				<!-- <view class="deduct" v-if="specsIndex!=-1">
					<view class="each">
						<image src="../../static/svgIcon/deduct1.svg" mode=""></image>
						金币可抵{{specs[specsIndex].score_deduction}}元
					</view>
					<view class="each">
						<image src="../../static/svgIcon/deduct2.svg" mode=""></image>
						高粱穗可抵{{specs[specsIndex].coin_deduction}}元
					</view>
				</view> -->
				<!-- 领券 -->
				<view class="collectCoupons" v-if="promotion.length!=0" @tap="couponShowGo">
					领券
					<view class="each" v-for="(cous,j) of promotion" :key="j">
						{{cous.promotion_condition[0].result.substring(0,10)}}元
						<view class="yuanL"></view>
						<view class="yuanR"></view>
					</view>
				</view>
			</view>
			
			<!-- 购买选择 -->
			<view class="buyOptions" v-if="goodsInfo.goods_product">
				<view class="buyOptionsGo" @tap="goodsOpShowGo">
					<view class="opVal"><text class="lable">规格</text>{{specsIndex==-1?'':goodsInfo.goods_product[specsIndex].spec}}</view>
					<u-icon name="arrow-right" color="#999999" size="20"></u-icon>
				</view>
			</view>
			
			<!-- 酒卡攻略 -->
			<image v-if="isNomalVirtual==3" @click="cardStrGo" class="liquorCardStrategy" src="https://lovebirdopen.com/static/img/cBj/liquorCardStrategy2.png" mode=""></image>
			<!-- 评价 -->
			<!-- <view class="evaluate">
				<u-section title="评价" sub-title="" :show-line="false" font-size="28" :bold="false" color="#333333"></u-section>
				<view class="title">
					<text>评价</text>
					<view class="fr" @tap="goodsEvaluationGo">
						<u-icon name="arrow-right" color="#999999" size="28"></u-icon>
					</view>
				</view>
				<view>
					<u-empty text="暂无评论" v-if="g.length==0"></u-empty>
					<view class="evaluateList" v-for="(item,index) of evaluateList" :key="index">
						<view class="evaluateTop">
							<dh-image class="niccImg" :src="item.userInfo.avatar==null?'../../static/img/vector.svg':item.userInfo.avatar"
							 errorSrc="https://lovebirdopen.com/static/img/cBj/dPicture.png"></dh-image>
							<text class="nickName">{{item.userInfo.nickname==null?'暂无':item.userInfo.nickname}}</text>
							<u-rate v-model="scoreArr[index]" active-color="#EB4B34" gutter="6" size="22" :disabled="true"></u-rate>
							<view class="eTime">{{getdate(item.created_at,0)}}</view>
						</view>
						<view class="eCont">{{item.content}}</view>
						<scroll-view scroll-x="true" class="eImage">
							<view class="imgBox" v-for="(img,i) of item.imageItems" :key="i" @tap="seeImg(i,item.imageItems)">
								<dh-image class="niccImg" :src="img.file_url" errorSrc="https://lovebirdopen.com/static/img/cBj/dPicture.png"></dh-image>
							</view>
						</scroll-view>
					</view>
				</view>
			</view> -->
			
			<!-- 商品详情 -->
			<view class="goodsDetails">
				<!-- <u-section title="商品详情" sub-title="" font-size="28" line-color="#EB4B34" :bold="false" color="#333333" :arrow="false"></u-section> -->
				<view class="title">
					<text>商品详情</text>
				</view>
				<view class="goodsDetailsBox">
					<!-- <rich-text :nodes="goodsInfo.content"></rich-text> -->
					<u-parse :html="goodsInfo.content" class="detail-content"></u-parse>
				</view>
			</view>
			
			<!-- 详情立即抢购 -->
			<view class="handleBox" :style="{paddingBottom:isIphoneX?'76rpx':''}">
				<view class="buyNowBtn" style="height:82rpx ;" @tap="confirmOrder">立即抢购</view>
				<!-- <author-login @clickAgain="confirmOrder" height="82rpx" bgColor="linear-gradient(276.81deg, #FF5238 8.46%, #FFA360 89.67%), #FF5238;" fontColor="#fff" title="立即抢购" borderRadius="44rpx"></author-login> -->
			</view>
			
			<!-- 优惠券选择 -->
			<u-popup v-model="couponShow" mode="bottom" border-radius="8">
				<view class="addPopTit">可用优惠券</view>
				<view class="couponLqBox" v-if="promotion.length>0">
					<scroll-view class="couponLqBoxScroll" scroll-y="true">
						<view class="couponEach" v-for="(item,index) of promotion" :key="index">
							<view class="couponEachCont" :class="{boxShadow:cIndex == index && ruleShow}">
								<view class="couponEachSide">
									<view class="sideLeft">
										<view class="circle1"></view>
										<view class="circle2"></view>
										<view class="sideLeftCont">
											<view class="amount"><text>¥</text>{{item.promotion_condition[0].result}}</view>
											<view class="tips">{{item.name}}</view>
										</view>
									</view>
									<view class="sideRight">
										<view class="circle1"></view>
										<view class="circle2"></view>
										<view class="sideRightCont">
											<view class="title ellipsis"><text>{{item.owner_id==1?'平台专享':'通用优惠券'}}</text></view>
											<view class="use">{{(item.end_time)}}前使用</view>
											<view class="useRule" @tap="seeRule(index)">使用规则<u-icon name="arrow-down" color="#999999" size="12"></u-icon></view>
										</view>
									</view>
								</view>
							</view>
							<view class="couponBtn" :class="{couponBtnEd:item.promotion_coupon}">{{item.promotion_coupon?'已领取':'立即领取'}}</view>
							<view class="couponBtnEmpty" v-if="!item.promotion_coupon"></view>
							<view class="couponBtnEmpty" v-if="!item.promotion_coupon" @tap="receiveCoupon(item.promotion_coupon.id)"></view>
							<!-- 已领取图标 -->
							<image class="claimedIcon" v-if='item.promotion_coupon' src="../../static/img/received.svg"></image>
							
							<view class="ruleContent" v-if="ruleShow && cIndex == index" :data-index="index">
								<view class="ruleInfo">{{item.instruction}}</view>
							</view>
						</view>
					</scroll-view>
				</view>
			</u-popup>
			
			<!-- 弹窗 规格选择-->
			<u-popup v-model="goodsOpShow" mode="bottom" border-radius="16">
				<view class="purchase">
					<view class="goodsBox">
						<dh-image class="niccImg" :src="goodsInfo.image" errorSrc="https://lovebirdopen.com/static/img/cBj/dPicture.png"></dh-image>
						<!-- <image :src="specsIndex==-1?goodsInfo.image:goodsInfo.image"></image> -->
						<view class="goodsOpInfo">
							<view class="title mb8">{{specsIndex==-1?goodsInfo.name:goodsInfo.goods_product[specsIndex].name}}</view>
							<view class="stock mb8">库存{{specsIndex==-1?goodsInfo.goods_product[0].stock:goodsInfo.goods_product[specsIndex].stock}}件</view>
							<view class="price">￥{{specsIndex==-1?goodsInfo.price:goodsInfo.goods_product[specsIndex].price}}</view>
						</view>
					</view>
					<view class="purchaseNumC">
						<view class="recordBox">
							<view class="title"><text style="margin-right: 20rpx;">购买数量</text>{{purchaseNum}}{{goodsInfo.stock_unit}}</view>
						</view>
						<view class="">
							<u-number-box v-model="purchaseNum" min="1" :max="specsIndex==-1?goodsInfo.goods_product[0].stock:goodsInfo.goods_product[specsIndex].stock" @change="valChange"></u-number-box>
						</view>
					</view>
					<view class="specsBox">
						<view class="title">规格信息</view>
						<view class="specsItems">
							<view class="specsItem" v-for="(item,index) in goodsInfo.goods_product" :key="index" @tap="specsTab(index)" :class="{specsItemEd:specsIndex == index}">{{item.spec}}</view>
						</view>
					</view>
				</view>
				<view class="buyNow">
					<view class="buyNowBtn" @tap="confirmOrder">去下单</view>
				</view>
			</u-popup>
			
			<!-- 返回顶部、分享 -->
			<view class="shareBtn" v-if="shareBtnShow">
				<button class="btnShare"   @click="shareGo">
					<image src="../../static/img/share.svg" mode=""></image>
					<text>分享</text>
				</button>
				<!-- <author-login @clickAgain="shareGo" height="60rpx" bgColor="#FF5238" butImg="../../static/img/share.svg" title="分享"></author-login> -->
			</view>
			<u-back-top :scrollTop="scrollTop" top="100" :custom-style="topStyle" right="32"></u-back-top>
			
			<!--弹窗 分享选择-->
			<u-popup v-model="shareWayShow" mode="bottom" border-radius="16">
				<view class="shareWaysBox">
					<view class="shareWays">
						<view class="shareWaysEach">
							<button class="shareFriendsBtn" open-type="share" :plain="true" @click="cancelShare">
								<view class="shareWaysEachIcon">
									<u-icon name="weixin-fill" color="#2DC100" size="48"></u-icon>
								</view>
								<view class="tit">微信好友分享</view>
							</button>
						</view>
						<view class="shareWaysEach" @tap="generateGo">
							<view class="shareWaysEachIcon">
								<u-icon name="photo-fill" color="#666666" size="48"></u-icon>
							</view>
							<view class="tit">生成海报</view>
						</view>
					</view>
					<!-- 取消 -->
					<view class="cancel" @tap="cancelShare">取消</view>
				</view>
			</u-popup>
			
			<!-- 弹窗  海报-->
			<u-popup v-model="painterShow" mode="bottom" border-radius="16">
				<view class="goodsPainter">
					<image :src="posterPath" mode="" v-if="posterPath!=''"></image>
				</view>
				<view class="savePainter">
					<view class="saveBtn" @tap="savePoster">保存图片</view>
				</view>
			</u-popup>
			
			<view class="painterCans">
				<lime-painter :board="myGoods" v-if="isGenerate==1" :isRenderImage="true" @success="posterPath = $event" @fail=""></lime-painter>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				url:'/api/user/moreTableList', //接口地址
				scene:null,
				// 手机机型
				modelmes:null,
				isIphoneX:false,
				// id
				goodsId: null,
				specsId:null,
				// 商品类型  is_nomal_virtual   1实体商品 2虚拟商品 3酒卡商品
				isNomalVirtual:null,
				// 商品详情
				goodsInfo: null,
				bannerList: [],
				promotion:[],//优惠券
				bannerSet: {
					duration: 500
				},
				bCurrent: 0,
				// 关注图标
				isFollow:false,
				// 商品评价
				evaluateList: [],
				scoreArr: [],
				buyUser: null,
				timer: null ,// 定时器
				// 分享
				shareWayShow: false,
				painterShow: false,
				shareImg: '',
				invitationCode:'',
				// 生成海报相关参数
				isGenerate: 0,
				posterPath: '',
				myGoods: {
					width: "570rpx",
					height: "903rpx",
					background: "#ffffff",
					views: [
						{ //0产品图
							type: "image",
							url: "",
							css: {
								width: "528rpx",
								height: "528rpx",
								top: "30rpx",
								left: "21rpx",
								mode: "center",
								radius: '16rpx 16rpx 0 0'
							}
						},
						{
							type: 'view',
							css: {
								width: '530rpx',
								height: '120rpx',
								left: '20rpx',
								top: '528rpx',
								background: '#fff',
								shadow: '0 20rpx 48rpx rgba(0,0,0,.05)',
								radius: '0 0 16rpx 16rpx'
							}
						},
						{
							type: "image",
							url: "https://lovebirdopen.com/static/img/poster/ld.png",
							css: {
								width: "40rpx",
								height: "40rpx",
								top: "536rpx",
								left: "37rpx",
								mode: "center"
							}
						},
						{
							type: "image",
							url: "https://lovebirdopen.com/static/img/poster/rd.png",
							css: {
								width: "40rpx",
								height: "40rpx",
								top: "596rpx",
								left: "490rpx",
								mode: "center"
							}
						},
						{ //4产品名称
							type: 'text',
							text: '',
							css: {
								width: '500rpx',
								maxLines: 2,
								color: '#333',
								left: '37rpx',
								top: '560rpx',
								fontSize: '22rpx',
								lineHeight: '34rpx'
							}
						},
						{
							type: 'view',
							css: {
								width: '528rpx',
								height: '210rpx',
								left: '21rpx',
								top: '660rpx',
								background: '#fff',
								shadow: '0 20rpx 48rpx rgba(0,0,0,.05)',
								radius: '16rpx'
							}
						},
						{ //6用户头像
							type: "image",
							url: "",
							css: {
								width: "60rpx",
								height: "60rpx",
								top: "690rpx",
								left: "37rpx",
								radius: "50%",
								mode: "scaleToFill"
							}
						},
						{ //7用户名称
							type: 'text',
							text: '',
							css: {
								width: '260rpx',
								maxLines: 1,
								color: '#333',
								left: '110rpx',
								top: '690rpx',
								fontSize: '22rpx',
								lineHeight: '34rpx'
							}
						},
						{
							type: 'text',
							text: '给你推荐了一个好东西',
							css: {
								width: '260rpx',
								maxLines: 1,
								color: '#666',
								left: '110rpx',
								top: '720rpx',
								fontSize: '20rpx',
								lineHeight: '34rpx'
							}
						},
						{
							type: 'text',
							text: '¥',
							css: {
								width: '32rpx',
								maxLines: 1,
								color: '#FF5238',
								left: '37rpx',
								top: '780rpx',
								fontSize: '20rpx',
								lineHeight: '38rpx'
							}
						},
						{ //10产品价格
							type: 'text',
							text: '',
							css: {
								width: '320rpx',
								maxLines: 1,
								color: '#FF5238',
								left: '50rpx',
								top: '780rpx',
								fontSize: '32rpx',
								lineHeight: '36rpx'
							}
						},
						{ //11产品简介
							type: 'text',
							text: '',
							css: {
								width: '320rpx',
								maxLines: 1,
								color: '#333',
								left: '37rpx',
								top: '820rpx',
								fontSize: '22rpx',
								lineHeight: '24rpx'
							}
						},
						{ //12小程序码https://lovebirdopen.com
							type: "image",
							url: "",
							css: {
								width: "140rpx",
								height: "140rpx",
								top: "674rpx",
								left: "380rpx",
								mode: "scaleToFill"
							}
						},
						{
							type: 'text',
							text: '·',
							css: {
								width: '30rpx',
								maxLines: 1,
								color: '#333',
								left: '360rpx',
								top: '818rpx',
								fontSize: '40rpx',
								lineHeight: '36rpx',
								textAlign: 'center'
							}
						},
						{
							type: 'text',
							text: '·',
							css: {
								width: '30rpx',
								maxLines: 1,
								color: '#333',
								left: '510rpx',
								top: '818rpx',
								fontSize: '40rpx',
								lineHeight: '36rpx',
								textAlign: 'center'
							}
						},
						{
							type: 'text',
							text: '长按立即购买',
							css: {
								width: '140rpx',
								maxLines: 1,
								color: '#333',
								left: '380rpx',
								top: '824rpx',
								fontSize: '22rpx',
								lineHeight: '22rpx',
								textAlign: 'center'
							}
						},
					]
				},
				// 规格
				specs: [],
				specsIndex: -1,
				// 浮动分享按钮
				shareBtnShow: false,
				// 浮动返回顶部按钮
				scrollTop: 0,
				topStyle: {
					width: '96rpx',
					height: '96rpx',
					background: 'rgba(255, 255, 255, 0.7)',
					border: '2rpx solid #CCCCCC',
					borderRadius: '50%'
				},
				//优惠券,
				couponShow:false,
				ruleShow:false,
				cIndex:'',
				// 选择规格和数量弹窗
				goodsOpShow: false,
				// 选择的商品数量
				purchaseNum: 1,
				//提货方式和数量进行本地储存以便确认订单使用
				orderRecord:{
					methodItem:1,//提货方式
					num:1//商品数量
				},
			}
		},
		onLoad: function(option) {
			// 判断机型iPhone X的
			this.modelmes = uni.getStorageSync('modelmes');
			if (this.modelmes.search('iPhone X') != -1) {
			   this.isIphoneX = true;
			}
			if(option.scene){
				this.scene = this.resolvingScene(option.scene);
				if(this.scene.ref){
					uni.setStorage({
						key: 'refVal',
						data: this.scene.ref,
						success: function () {
							console.log('success');
						}
					});
				}
				this.goodsId = this.scene.id;
			}
			if(option.id){
				this.goodsId = option.id;
				if (!uni.getStorageSync('userInfo')) {
					//用户登录
					this.login();
				} else {
					//调用默认启动方法
					this.loadData();
				}
			}
			if(option.ref){
				uni.setStorage({
				    key: 'refVal',
				    data: option.ref,
				    success: function () {
				        console.log('success');
				    }
				});
			}
			// this.getGoodsInfo(this.goodsId); //产品详情
			// this.getEvaluateList(this.goodsId); //产品评价
			// this.getBuyUser(this.goodsId); //购买此产品的用户
		},
		onPageScroll(e) {
			if (e.scrollTop < 100) {
				this.shareBtnShow = false;
			}
			if (e.scrollTop > 100) {
				this.shareBtnShow = true;
			}
			this.scrollTop = e.scrollTop;
		},
		methods: {
			
			loadData() {
				this.get_goodsData();//商品详情查询(多表查询)
				this.get_promotion();//优惠券查询(多表查询)
			},
			
			//--------------------多表查询案例（商品信息  评价 购买过的人 ）
			async get_goodsData() {
				//-------主表查询参数
				let param = {};
				param.db = 1; //0获取缓存数据  1 获取非缓存数据  默认0
				param.dbNum = ''; //缓存编号   API默认以MD5(param)为编号
				param.table = 'goods';//主表名称
				param.listType = 2; //2查询全部  3分页查询
				param.order = ''; //表无自增ID时追加为默认排序 无需给个字符空值
				param.linkfield = 'id'; //主表关联字段名称（为空则非关联多表查询）
				param.where = {'id':this.goodsId}; //主表查询条件 无需给个字符空值
				param.table_list =[];//多表参数数组名称 无需给个字符空或空数组
				
				//-------主表查询参数（规格表）
				// let param2 = {};
				// param2.table="goods_attr";//多表名称
				// param2.listType = 2; //1查单条 2查询全部
				// param2.order = ''; //表无自增ID时追加为默认排序 无给个字符空值
				// param2.linkfield = 'id'; //多表关联字段名称（主表为空无效，本表无需关联查询可为字符空）
				// param2.where = {}; //查询条件 无需给个字符空值
				// param.table_list.push(param2);//追加多表查询参数  无需注释掉
				
				//-------主表查询参数（单品表）
				let param3 = {};
				param3.table="goods_product";//多表名称
				param3.listType = 2; //1查单条 2查询全部
				param3.order = ''; //表无自增ID时追加为默认排序 无给个字符空值
				param3.linkfield = 'goods_id'; //多表关联字段名称（主表为空无效，本表无需关联查询可为字符空）
				param3.where = {}; //查询条件 无需给个字符空值
				param.table_list.push(param3);//追加多表查询参数  无需注释掉
				
				//-------主表查询参数（商品评价表）
				// let param4 = {};
				// param4.table="goods_comment";//多表名称
				// param4.listType = 2; //1查单条 2查询全部
				// param4.order = ''; //表无自增ID时追加为默认排序 无给个字符空值
				// param4.linkfield = 'goods_id'; //多表关联字段名称（主表为空无效，本表无需关联查询可为字符空）
				// param4.where = {}; //查询条件 无需给个字符空值
				// param.table_list.push(param4);//追加多表查询参数  无需注释掉
			
				const res = await this.$fly.post(this.url, {
					msg: JSON.stringify(param)
				});
				
				if (res.code == 200) {
					this.goodsInfo=res.data[0]
					res.data[0].pic.forEach(item=>{
						this.bannerList.push(this.fileUrl(item))
						this.goodsInfo.image=this.fileUrl(item)
					})
					this.posterPath=this.goodsInfo.image
					console.log(res.data)
				} else {
					console.log(res);
				}
			},
			
			//--------------------多表查询案例（店铺优惠券 ）
			async get_promotion(){
				//-------主表查询参数（优惠券--商户）
				let param = {};
				param.db = 1; //0获取缓存数据  1 获取非缓存数据  默认0
				param.table="promotion";//多表名称
				param.listType = 2; //1查单条 2查询全部
				param.order = ''; //表无自增ID时追加为默认排序 无给个字符空值
				param.linkfield = 'id'; //多表关联字段名称（主表为空无效，本表无需关联查询可为字符空）
				param.where = {'owner_id':uni.getStorageSync('shop_id'),'type':1}; //查询条件 无需给个字符空值
				param.table_list=[];//多表参数数组名称 无需给个字符空或空数组
				
				//-------主表查询参数（优惠券--商户）
				let param2 = {};
				param2.table="promotion_condition";//多表名称
				param2.listType = 2; //1查单条 2查询全部
				param2.order = 'sort Asc'; //表无自增ID时追加为默认排序 无给个字符空值
				param2.linkfield = 'promotion_id'; //多表关联字段名称（主表为空无效，本表无需关联查询可为字符空）
				param2.where = {
								'end_at':['>',uni.getStorageSync('userInfo').time],
								'start_at':['<',uni.getStorageSync('userInfo').time]
							   }; //查询条件 无需给个字符空值
				param.table_list.push(param2);//追加多表查询参数  无需注释掉
				
				//-------主表查询参数（优惠券--用户）
				let param3 = {};
				param3.table="promotion_coupon";//多表名称
				param3.listType = 2; //1查单条 2查询全部
				param3.order = ''; //表无自增ID时追加为默认排序 无给个字符空值
				param3.linkfield = 'promotion_id'; //多表关联字段名称（主表为空无效，本表无需关联查询可为字符空）
				param3.where = {}; //查询条件 无需给个字符空值
				param.table_list.push(param3);//追加多表查询参数  无需注释掉
				
				const res = await this.$fly.post(this.url, {
					msg: JSON.stringify(param)
				});
				
				
				if (res.code == 200) {
					res.data.forEach(item=>{ 
						//时间戳转换日子格式
						item.end_time=this.fmtDate(item.end_at)
					})
					this.promotion=res.data
					console.log(res.data)
				} else {
					console.log(res);
				}
				
			},
			
			
			// getLogonUser() {
			// 	this.apiget('/fun/member/view', {}).then(res => {
			// 		if (res.data.status == 200) {
			// 			this.myGoods.views[6].url = res.data.data.avatar;
			// 			this.myGoods.views[7].text = res.data.data.nickname;
			// 			this.invitationCode = res.data.data.invitation_code;
			// 			// 获取小程序码
			// 			this.gerWxCode();
			// 		}
			// 	})
			// },
			
			gerWxCode(){
				this.apipost('/wxxcx/get-wx-code', {page:'pages/index/goodsInfo',scene:'id='+this.goodsId+'&ref='+this.invitationCode,width:280,is_hyaline:1}).then(res => {
					if (res.data.status == 200) {
						this.myGoods.views[12].url = res.data.data;
						this.isGenerate = 1;
					}
				})
			},
			
			// getGoodsInfo(id) {
			// 	this.apiget('/fun/goods/view', {
			// 		id: id
			// 	}).then(res => {
			// 		if (res.data.status == 200) {
			// 			// this.goodsInfo = res.data.data;
			// 			this.isNomalVirtual = res.data.data.is_nomal_virtual;
			// 			// this.bannerList = res.data.data.imageItems;
			// 			this.isFollow = res.data.data.is_collection==0?false:true;
			// 			this.myGoods.views[0].url = res.data.data.image;
			// 			this.myGoods.views[4].text = res.data.data.name;
			// 			this.myGoods.views[10].text = res.data.data.price;
			// 			this.myGoods.views[11].text = res.data.data.brief;
			// 			// this.shareImg = res.data.data.image;
			// 			this.specs = res.data.data.productItems;
			// 			// this.specsId = res.data.data.productItems[this.specsIndex].id;
			// 		}
			// 	})
			// },
			// banner图切换
			
			bannerChange(e) {
				this.bCurrent = e.detail.current;
				uni.createVideoContext('bannerVideo').pause(); //暂停视频
			},
			// 购买用户
			getBuyUser(id) {
				var _this = this;
				this.apiget('/fun/goods/goods-buy-user', {goods_id: id}).then(res => {
					if (res.data.status == 200) {
						var buyUser = res.data.data;
						var clauses = 0;
						if (buyUser.length > 0) {
							this.timer = setInterval(() => {
								if(clauses<buyUser.length){
									this.buyUser = buyUser[clauses];
									clauses++;
								}else{
									this.buyUser = null;
									// 清除定时器
									clearInterval(this.timer);
									this.timer = null;
								}
							}, 6000);
							// _this.buyUser.status = 1;
							// setTimeout(function() {
							// 	_this.buyUser.status = 0;
							// }, 6000);
						}
					}
				})
			},
			
			// 获取商品评价
			getEvaluateList(id) {
				var _this = this;
				this.apiget('/fun/goods/comment', {
					goods_id: id
				}).then(res => {
					if (res.data.status == 200) {
						var list = res.data.data.list;
						var eList = list.filter(v => {
							return v.status == 1;
						});
						// _this.evaluateList = _this.evaluateList.concat(eList);
						_this.evaluateList = eList.slice(0, 2);
						_this.evaluateList.forEach((v, i) => {
							_this.scoreArr.push(v.score);
						})
					}
				})
			},
			
			// 预览图片
			seeImg(index, imageItems) {
				var imgUrls = [];
				imageItems.forEach((v, i) => {
					imgUrls.push(v.file_url);
				});
				// 预览图片
				uni.previewImage({
					current: index,
					urls: imgUrls
				});
			},
			// 商品评价页面
			goodsEvaluationGo() {
				uni.navigateTo({
					url: './goodsEvaluation?id=' + this.goodsId
				});
			},
			
			valChange(e) {
				this.purchaseNum = e.value;
			},
			
			okChoice(){
				this.orderRecord.num = this.purchaseNum;
				this.orderRecord.methodItem = 1;
				this.goodsOpShow = false;
			},
			
			// 去下单
			confirmOrder() {
				if(this.specsIndex==-1){
					uni.showToast({
						icon: 'none',
						duration:1000,
						title: '请选择规格'
					});
					this.goodsOpShow=true
					return false;
				}else{
					uni.navigateTo({
						url: '../order/confirmOrder?id=' + this.specsId
					});
					let objShop ={
						num:this.purchaseNum,
						checkedShop:this.goodsInfo.goods_product[this.specsIndex],
						image:this.goodsInfo.image,
						goodsInfo:this.goodsInfo
					}
					uni.setStorageSync('checkedShop',objShop)
				}
				// var _this = this;
				// if (uni.getStorageSync('TOKEN')) {
				// 	this.testToken('/site/get-info',{}).then(res => {
				// 		if(res.data.status==200){//token有效
				// 			uni.setStorage({
				// 			    key: 'orderRecord',
				// 			    data: this.orderRecord
				// 			});
				// 			uni.navigateTo({
				// 				url: '../order/confirmOrder?id=' + this.specsId
				// 			});
				// 		}
				// 	})
				// }
			},
			
			// 分享
			cancelShare() {
				this.shareWayShow = false;
			},
			
			// 分享按钮
			shareGo() {
				// var _this = this;
				this.shareWayShow = true
				// if (uni.getStorageSync('TOKEN')) {
				// 	this.testToken('/site/get-info',{}).then(res => {
				// 		if(res.data.status==200){//token有效
				// 			_this.getLogonUser(); //当前登录用户
				// 			_this.shareWayShow = true;
				// 		}
				// 	})
				// }
			},
			
			// 关注商品
			followGo(){
				var _this = this;
				if (uni.getStorageSync('TOKEN')) {
					this.testToken('/site/get-info',{}).then(res => {
						if(res.data.status==200){//token有效
							var type = this.isFollow?'cancel':'create';
							this.collection(type);
						}
					})
				}
			},
			
			collection(type){
				this.apipost('/fun/collection/'+type,{source_id:this.goodsId,type:0}).then(res =>{
					if(res.data.status == 200 ) {
						uni.showToast({
							icon: 'success',
							duration:1000,
							title: res.data.message,
							success: res => {
								this.isFollow = !this.isFollow;
							},
						});
					}
				})
			},
			
			// 生成海报
			generateGo() {
				this.showLoadGo(true);
				this.painterShow = true;
				this.shareWayShow = false;
				if(this.posterPath!=''){
					this.showLoadGo(false);
				}
			},
			
			// 保存海报
			savePoster() {
				var _this = this;
				uni.saveImageToPhotosAlbum({
					filePath: this.posterPath,
					success(res) {
						uni.showToast({
							title: '已保存到相册',
							icon: 'success',
							duration: 2000,
							success: function() {
								_this.painterShow = false
							}
						})
					}
				})
			},
			
			// 优惠券领取
			couponShowGo(){
				this.couponShow = true;
			},
			// 更多规则
			seeRule(index){
				this.ruleShow = !this.ruleShow;
				this.cIndex = index;
			},
			// 领取优惠券
			receiveCoupon(id){
				var _this = this;
				this.apiget('/fun/coupon/receive',{promotion_id:id}).then(res =>{
					if(res.data.status == 200 ) {
						if(res.data.message == 'SUCCESS'){
							uni.showToast({
								icon: 'success',
								duration:1000,
								title: '领取成功',
								success: res => {
									setTimeout(function (){
										// _this.getGoodsInfo(_this.goodsId);
									}, 1000);
								},
							});
						}
					}
				})
			},
			
			// 先用不到的
			goodsOpShowGo() {
				this.goodsOpShow = true;
			},
			
			// 规格选择
			specsTab(index) {
				if(this.specsIndex == index){
					this.specsIndex = -1;
					this.specsId = null;
				}else{
					this.specsIndex = index;
					// this.specsId = this.specs[this.specsIndex].id;
					this.specsId = this.goodsInfo.goods_product[this.specsIndex].id;
				}
			},
			
			// 酒卡攻略
			cardStrGo(){
				uni.navigateTo({
					url: '../scanCode/cardStrategy'
				});
			},
		},
		
		onShareAppMessage(res) {
			var _this = this;
			return {
				title: _this.goodsInfo.name,
				// path: 'pages/index/goodsInfo?id=' + _this.goodsId + '&ref='+_this.invitationCode,
				path: 'pages/index/goodsInfo?id=' + _this.goodsId + 'user_id='+uni.getStorageSync('userInfo').user_id + 'owen_id='+uni.getStorageSync('shop_id'),
				imageUrl: this.goodsInfo.image
			}
			if (res.from === 'button') { // 来自页面内分享按钮
				uni.showToast({
					title: '已发送',
					icon: 'success',
					duration: 2000,
					success: function() {
						_this.shareWayShow = false;
					}
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
	.btnShare{
		height:60rpx;
		font-size: 32rpx;
		border: none;
		background-color:transparent ;
		color: white;
		line-height: 60rpx;
	}
	
	.goodsInfo {
		min-height: 100%;
		padding-bottom: 200rpx;
		background: #F8F8FA;
	}

	.shareBtn {
		display: flex;
		align-items: center;
		justify-content: center;
		position: fixed;
		bottom: 335rpx;
		right: 0;
		width: 144rpx;
		height: 60rpx;
		background: #FF5238;
		border-radius: 40rpx 0px 0px 40rpx;
		overflow: hidden;

		image {
			float: left;
			margin-top: 10rpx;
			margin-right: 8rpx;
			width: 40rpx;
			height: 40rpx;
		}
	}

	.goodsBanner {
		position: relative;
		height: 750rpx;

		.bannerBox {
			position: relative;
			width: 100%;
			height: 100%;

			.swiper {
				width: 100%;
				height: 100%;

				.bannerImgBox {
					width: 100%;
					height: 100%;
					text-align: center;

					.banner {
						width: 100%;
						height: 100%;
					}

					video {
						height: 100%;
						width: 100%;
						margin: 0 auto;
					}
				}
			}

			.swiperDots {
				position: absolute;
				bottom: 24rpx;
				right: 0;
				width: 100%;
				text-align: center;
				font-size: 0;
				
				.swiperDot{
					display: inline-block;
					width: 16rpx;
					height: 8rpx;
					margin: 0 4rpx;
					background: #D6E4FF;
					opacity: 0.4;
					border-radius: 2rpx;
				}
				
				.swiperDotActive{
					width: 32rpx;
					background: #FF5238;
					opacity: 1;
				}
			}

			.swiperNumber {
				position: absolute;
				bottom: 16rpx;
				right: 32rpx;
				padding: 4rpx 24rpx;
				line-height: 32rpx;
				background-color: rgba(0, 0, 0, 0.3);
				border-radius: 40rpx;
				font-size: 22rpx;
				color: #fff;
			}
		}

		.buyNotice {
			position: fixed;
			display: inline-block;
			top: 120rpx;
			left: 32rpx;
			padding: 8rpx 16rpx 8rpx 8rpx;
			background: rgba(255, 255, 255, 0.7);
			border-radius: 42rpx;

			.buyNoticeCont {
				display: flex;
				align-items: center;
				font-size: 24rpx;
				color: #333;

				image {
					width: 48rpx;
					height: 48rpx;
					margin-right: 16rpx;
					border-radius: 50%;
				}
			}
		}
	}

	.goodsInformation {
		padding: 28rpx 32rpx 24rpx;
		margin-bottom: 16rpx;
		background-color: #fff;

		.priceShare {
			display: flex;
			align-items: center;
			margin-bottom: 28rpx;

			.priceInfo {
				flex: auto;
				line-height: 60rpx;
				color: #FF1A1A;

				.unit {
					font-size: 36rpx;
				}

				.pPrice {
					font-size: 60rpx;
				}

				.oPrice {
					margin-left: 16rpx;
					font-size: 24rpx;
					color: #999;
					text-decoration: line-through
				}
			}

			.shareXBtn {
				width: 48rpx;
				height: 48rpx;

				image {
					width: 48rpx;
					height: 48rpx;
				}
			}
		}

		.goodsName {
			margin-bottom: 8rpx;
			font-size: 36rpx;
			line-height: 52rpx;
			color: #333;
		}

		.sales {
			margin-bottom: 16rpx;
			font-size: 24rpx;
			line-height: 40rpx;
			color: #666666;

			.fr {
				float: right;
			}
		}

		.deduct{
			height: 40rpx;
			margin-bottom: 16rpx;
			.each{
				display: inline-block;
				padding: 0 8rpx 0 12rpx;
				height: 40rpx;
				margin-right: 16rpx;
				line-height: 40rpx;
				font-size: 24rpx;
				color: #FF8A1E;
				background: rgba(255, 138, 30, 0.12);
				border-radius: 4rpx;
				
				image{
					width: 32rpx;
					height: 32rpx;
					margin-right: 8rpx;
					float: left;
					margin-top: 4rpx;
				}
			}
		}
		.collectCoupons{
			padding: 10rpx 0;
			font-size: 24rpx;
			line-height: 40rpx;
			color: #FF5238;
			
			.each{
				position: relative;
				display: inline-block;
				padding: 0 16rpx;
				margin-left: 24rpx;
				margin-bottom: 8rpx;
				background-color: #FF5238;
				font-size: 22rpx;
				line-height: 40rpx;
				color: #fff;
				
				.yuanL{
					position: absolute;
					top: 50%;
					left: -6rpx;
					width: 12rpx;
					height: 12rpx;
					background-color: #fff;
					margin-top: -6rpx;
					border-radius: 50%;
				}
				.yuanR{
					position: absolute;
					top: 50%;
					right: -6rpx;
					width: 12rpx;
					height: 12rpx;
					background-color: #fff;
					margin-top: -6rpx;
					border-radius: 50%;
				}
			}
		}
	}

	.buyOptions {
		padding: 0 32rpx;
		margin-bottom: 16rpx;
		background-color: #fff;

		.buyOptionsGo {
			display: flex;
			padding: 34rpx 0;
			line-height: 44rpx;
			font-size: 28rpx;
			color: #666666;

			.opVal {
				flex: auto;
				padding-right: 40rpx;
				overflow: hidden;
				text-overflow: ellipsis;
				white-space: nowrap;

				.lable {
					margin-right: 34rpx;
					color: #333333;
				}
			}
		}
	}
	
	.liquorCardStrategy{
		width: 100%;
		height: 240rpx;
		margin-bottom: 16rpx;
	}

	.evaluate {
		padding: 0 32rpx;
		background-color: #fff;

		.title {
			padding: 18rpx 0;
			font-size: 28rpx;
			color: #333333;

			.fr {
				float: right;
				padding-left: 80rpx;
			}
		}
	}

	.evaluateTop {
		display: flex;
		align-items: center;
		padding: 16rpx 0;
		font-size: 24rpx;

		.niccImg {
			width: 64rpx;
			height: 64rpx;
			margin-right: 8rpx;
			border-radius: 50%;
			overflow: hidden;
		}

		.nickName {
			margin-right: 17rpx;
			color: #333;
		}

		.eTime {
			flex: auto;
			text-align: right;
			color: rgba(0, 0, 0, 0.56);
		}
	}

	.eCont {
		padding: 8rpx 0;
		font-size: 24rpx;
		line-height: 36rpx;
		color: #333333;
	}

	.eImage {
		// width: calc(100%);
		// height: 160rpx;
		padding-bottom: 32rpx;
		display: flex;
		align-items: center;
		white-space: nowrap;
		box-shadow: inset 0px -0.5px 0px #ECEEF0;

		.imgBox {
			display: inline-block;
			width: 160rpx;
			height: 100%;
			border-radius: 8rpx;
			margin-right: 8rpx;

			.niccImg {
				display: inline-block;
				width: 100%;
				height: 100%;
				border-radius: 8rpx;
			}
		}
	}

	.goodsDetails {
		margin-top: 14rpx;

		.title {
			padding: 32rpx 0;
			background-color: #fff;

			text {
				padding-left: 24rpx;
				font-size: 28rpx;
				color: #333333;
				border-left: 8rpx solid #EB4B34;
			}
		}

		.goodsDetailsBox {
			padding: 32rpx;
		}
	}

	.handleBox {
		position: fixed;
		bottom: 0;
		left: 0;
		width: 100%;
		// display: flex;
		align-items: center;
		padding: 8rpx 32rpx;
		background-color: #fff;

		.handleFl {
			flex: auto;

			.price {
				font-size: 36rpx;
				line-height: 42rpx;
				color: #FF5238;

				text {
					font-size: 24rpx;
				}
			}

			.tips {
				font-size: 22rpx;
				line-height: 32rpx;
				text-decoration: line-through;
			}
		}

		.buyNowBtn {
			width: 100%;
			height: 82rpx;
			// padding: 18rpx 144rpx;
			text-align: center;
			font-size: 32rpx;
			line-height: 82rpx;
			color: #FFFFFF;
			background: linear-gradient(276.81deg, #FF5238 8.46%, #FFA360 89.67%), #FF5238;
			box-shadow: 0px 4rpx 8rpx rgba(255, 82, 56, 0.18);
			border-radius: 44rpx;
		}
	}

	// 弹窗
	.purchase {
		padding: 32rpx 32rpx 0;

		.goodsBox {
			display: flex;
			padding-bottom: 32rpx;

			.niccImg {
				width: 248rpx;
				height: 248rpx;
				margin-right: 16rpx;
				border-radius: 8rpx;
			}

			.goodsOpInfo {
				flex: auto;
				width: 1px;
				padding-top: 10rpx;

				.title {
					font-size: 32rpx;
					line-height: 48rpx;
					color: rgba(0, 0, 0, 0.84);
				}

				.stock {
					font-size: 24rpx;
					line-height: 36rpx;
					color: rgba(0, 0, 0, 0.56);
				}

				.price {
					font-size: 32rpx;
					line-height: 48rpx;
					color: #EB4B34;
				}

				.mb8 {
					margin-bottom: 8rpx;
				}
			}
		}

		.purchaseNumC {
			padding: 26rpx 0 16rpx;
			display: flex;
			align-items: center;

			.recordBox {
				flex: auto;

				.title {
					font-size: 28rpx;
					line-height: 44rpx;
					color: #333333;
				}

				.record {
					font-size: 24rpx;
					line-height: 40rpx;
					color: #666666;
				}
			}
		}

		.specsBox {
			padding: 32rpx 0 60rpx;

			.title {
				font-size: 28rpx;
				line-height: 44rpx;
				color: #333333;
			}

			.specsItems {
				padding-top: 8rpx;

				.specsItem {
					display: inline-block;
					margin: 8rpx;
					padding: 12rpx 24rpx;
					background-color: #ECEEF0;
					border: 2rpx solid #ECEEF0;
					border-radius: 44rpx;
					font-size: 24rpx;
					line-height: 40rpx;
					color: #666666;
				}

				.specsItemEd {
					background-color: #FEF1EF;
					border: 2rpx solid #EB4B34;
					color: #EB4B34;
				}
			}
		}
	}

	.addPopTit {
		padding: 24rpx 0;
		font-size: 32rpx;
		line-height: 48rpx;
		text-align: center;
		color: #333333;
	}

	.shipTo {
		padding: 0 32rpx 24rpx;

		.uni-list-cell {
			display: flex;
			align-items: center;
			padding: 24rpx 0;
			box-shadow: inset 0px -0.5px 0px #ECEEF0;

			.mr24 {
				margin-right: 24rpx;
			}
		}
	}

	.buyNow {
		padding: 8rpx 32rpx 76rpx;
		box-shadow: 0px -0.5px 0px #ECEEF0;

		.buyNowBtn {
			height: 84rpx;
			background: linear-gradient(276.81deg, #FF5238 8.46%, #FFA360 89.67%), #FF5238;
			box-shadow: 0px 4rpx 8rpx rgba(255, 82, 56, 0.18);
			border-radius: 42rpx;
			font-size: 32rpx;
			line-height: 84rpx;
			color: #fff;
			text-align: center;
		}
	}

	.rowupGo {
		animation: 6s rowup 0s infinite;
		-webkit-animation: 6s rowup 0s infinite;
		-moz-animation: 6s rowup 0s infinite;
	}

	// 领取优惠券弹窗
	.couponLqBox{
		height: 642rpx;
		padding: 40rpx 32rpx 64rpx;
		background-color: #F8F8FA;
		overflow-y: auto;
		
		.couponLqBoxScroll{
			width: 100%;
			height: 100%;
		}
		// 新优惠券
		.couponEach{
			position: relative;
			margin-bottom: 16rpx;
			min-height: 224rpx;
			padding-top: 196rpx;
			
			.couponEachCont{
				position: absolute;
				left: 0;
				top: 0;
				z-index: 2;
				height: 224rpx;
				width: 100%;
				padding-right: 94rpx;
				box-sizing: border-box;
				
				.couponEachSide{
					display: flex;
					align-items: center;
					width: 100%;
					height: 100%;
					padding-right: 16rpx;
					background-color: #fff;
					border-radius: 16rpx;
					
					.sideLeftCont{
						text-align: center;
						height: 100%;
						padding: 18rpx;
						border-right: 2rpx dashed #ccc;
						color: #FF5238;
						
						.amount{
							font-size: 72rpx;
							line-height: 56rpx;
							
							text{
								font-size: 32rpx;
							}
						}
						
						.tips{
							font-size: 24rpx;
							line-height: 34rpx;
						}
					}
					
					.sideLeft{
						position: relative;
						padding: 48rpx 0;
						width: 160rpx;
						height: 100%;
						
						.circle1{
							position: absolute;
							top: -14rpx;
							right: -14rpx;
							width: 28rpx;
							height: 28rpx;
							background-color: #F8F8FA;
							border-radius: 50%;
						}
						.circle2{
							position: absolute;
							bottom: -14rpx;
							right: -14rpx;
							width: 28rpx;
							height: 28rpx;
							background-color: #F8F8FA;
							border-radius: 50%;
						}
					}
					
					.sideRight{
						flex: 1;
						width: 1px;
						position: relative;
						padding: 48rpx 0 48rpx 32rpx;
						height: 100%;
						
						.sideRightCont{
							
							.title{
								font-size: 28rpx;
								line-height: 40rpx;
								color: #666666;
								
								text{
									color: #333333;
									font-weight: 700;
									margin-right: 16rpx;
								}
							}
							
							.use{
								margin-top: 8rpx;
								font-size: 24rpx;
								line-height: 34rpx;
								color: #666666;
							}
							
							.useRule{
								margin-top: 20rpx;
								font-size: 24rpx;
								line-height: 34rpx;
								color: #999999;
								
								.u-icon{
									margin-left: 10rpx;
								}
							}
						}
						
						.circle1{
							position: absolute;
							top: -14rpx;
							left: -14rpx;
							width: 28rpx;
							height: 28rpx;
							background-color: #F8F8FA;
							border-radius: 50%;
						}
						.circle2{
							position: absolute;
							bottom: -14rpx;
							left: -14rpx;
							width: 28rpx;
							height: 28rpx;
							background-color: #F8F8FA;
							border-radius: 50%;
						}
					}
				}
			}
			
			.boxShadow{
				box-shadow: 0px 4rpx 60rpx -2rpx rgba(0, 0, 0, 0.05);
			}
			
			.couponBtn{
				position: absolute;
				right: 0;
				top: 0;
				z-index: 1;
				width: 110rpx;
				height: 224rpx;
				padding: 20rpx 32rpx 20rpx 48rpx;
				box-sizing: border-box;
				display: flex;
				align-items: center;
				font-size: 28rpx;
				line-height: 36rpx;
				color: #FFFFFF;
				background: linear-gradient(90deg, #FF5238 33.5%, rgba(255, 82, 56, 0.7) 100%);
				box-shadow: 0px 4rpx 8rpx rgba(0, 0, 0, 0.02);
				border-radius: 0px 16rpx 16rpx 0px;
			}
			.couponBtnEd{
				background: #FFE2DE;
				color: #FF5238;
			}
			
			.couponBtnEmpty{
				position: absolute;
				right: 0;
				top: 0;
				z-index: 3;
				width: 110rpx;
				height: 224rpx;
			}
			
			.claimedIcon{
				position: absolute;
				right: 110rpx;
				top: 112rpx;
				z-index: 3;
				width: 80rpx;
				height: 80rpx;
			}
			
			.ruleContent{
				padding: 50rpx 48rpx 22rpx;
				background: #FFFFFF;
				border-radius: 0px 0px 16rpx 16rpx;
				
				.ruleInfo{
					position: relative;
					padding-left: 15px;
					font-size: 12px;
					line-height: 24px;
					color: #333;
				}
				.ruleInfo:after{
					position: absolute;
					content: '';
					top: 50%;
					left: 14rpx;
					width: 4rpx;
					height: 4rpx;
					margin-top: -2rpx;
					background-color: #333;
				}
			}
		}
	}
	// 动画

	@keyframes rowup {
		0% {
			transform: translateY(0);
			opacity: 0;
		}

		45% {
			transform: translateY(calc(-100%));
			opacity: 1;
		}

		55% {
			transform: translateY(calc(-100%));
			opacity: 1;
		}

		100% {
			transform: translateY(calc(-200%));
			opacity: 0;
		}
	}

	@-webkit-keyframes rowup {
		0% {
			transform: translateY(0);
			opacity: 0;
		}

		45% {
			transform: translateY(calc(-100%));
			opacity: 1;
		}

		55% {
			transform: translateY(calc(-100%));
			opacity: 1;
		}

		100% {
			transform: translateY(calc(-200%));
			opacity: 0;
		}
	}

	@-moz-keyframes rowup {
		0% {
			transform: translateY(0);
			opacity: 0;
		}

		45% {
			transform: translateY(calc(-110%));
			opacity: 1;
		}

		55% {
			transform: translateY(calc(-110%));
			opacity: 1;
		}

		100% {
			transform: translateY(calc(-220%));
			opacity: 0;
		}
	}


	//分享方式
	.shareWaysBox {
		padding: 64rpx 32rpx;

		.shareWays {
			display: flex;
			padding-bottom: 60rpx;
			text-align: center;

			.shareWaysEach {
				flex: 1;

				.shareFriendsBtn {
					border: none;
				}

				.shareWaysEachIcon {
					display: flex;
					align-items: center;
					justify-content: center;
					height: 112rpx;
					width: 112rpx;
					margin: 0 auto;
					background: #F7F7F7;
					border-radius: 8rpx;
				}

				.tit {
					margin-top: 16rpx;
					font-size: 24rpx;
					line-height: 40rpx;
					color: #999999;
				}
			}
		}

		.cancel {
			height: 96rpx;
			font-size: 32rpx;
			line-height: 96rpx;
			text-align: center;
			color: #333;
			background: #F7F7F7;
			border-radius: 48px;
		}
	}

	.goodsPainter {
		width: 570rpx;
		height: 903rpx;
		padding-top: 40rpx;
		margin: 0 auto;
		
		image{
			width: 570rpx;
			height: 903rpx;
		}
	}

	
	.painterCans {
		position: fixed;
		left: -800rpx;
		width: 570rpx;
		height: 903rpx;
	}

	.savePainter {
		margin-top: 52rpx;
		padding: 0 32rpx 68rpx;

		.saveBtn {
			height: 96rpx;
			font-size: 32rpx;
			line-height: 96rpx;
			color: #fff;
			text-align: center;
			background: #FF5238;
			box-shadow: 0px 4rpx 8rpx rgba(255, 82, 56, 0.18);
			border-radius: 48rpx;
		}
	}
</style>
